package com.flyco.modules.sms.entity;

import java.io.Serializable;
import java.util.Date;

import com.baomidou.mybatisplus.annotation.*;
import com.flyco.common.aspect.annotation.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
import com.flyco.poi.excel.annotation.Excel;

/**
 * @Description: 优惠券发放方式
 * @Author: flyco
 * @Date:   2020-03-04
 * @Version: V1.0
 */
@Data
@TableName("sms_coupon_grant")
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="sms_coupon_grant对象", description="优惠券发放方式")
public class SmsCouponGrant {
    
	/**id*/
	@TableId(type = IdType.AUTO)
    @ApiModelProperty(value = "id")
	private Long id;
	/**优惠券ID*/
	@Excel(name = "优惠券ID", width = 15)
    @ApiModelProperty(value = "优惠券ID")
	private Long couponId;
	/**获取类型：0->后台赠送；1->主动获取*/
	@Excel(name = "获取类型：0->后台赠送；1->主动获取", width = 15)
    @ApiModelProperty(value = "获取类型：0->后台赠送；1->主动获取")
	@Dict(dicCode = "coupon_get_type")
	private Integer getType;
	/**0-待发放 1-发放中 2-暂停 3-结束发放*/
	@Excel(name = "0-待发放 1-发放中 2-暂停 3-结束发放", width = 15)
    @ApiModelProperty(value = "0-待发放 1-发放中 2-暂停 3-结束发放")
	@Dict(dicCode = "coupon_grant_status")
	private Integer grantStatus;
	/**领券分组：normal：默认领券,live：直播领券 ,third：三方领券*/
	@Excel(name = "领券分组：normal：默认领券,live：直播领券 ,third：三方领券", width = 15)
	@ApiModelProperty(value = "领券分组：normal：默认领券,live：直播领券 ,third：三方领券")
	@Dict(dicCode = "coupon_grant_group")
	private String grantGroup;
	/**领券地址，默认UUID，可修改*/
	@Excel(name = "领券地址，默认UUID，可修改", width = 15)
	@ApiModelProperty(value = "领券地址，默认UUID，可修改")
	private String grantUuid;
	/**是否对外展示，0：不展示，1：展示*/
	@Excel(name = "是否对外展示，0：不展示，1：展示", width = 15)
	@ApiModelProperty(value = "是否对外展示，0：不展示，1：展示")
	@Dict(dicCode = "yn")
	private Integer showFlag;
	/**仅限新用户标识*/
	@Excel(name = "仅限新用户标识", width = 15)
	@ApiModelProperty(value = "仅限新用户标识")
	@Dict(dicCode = "yn")
	private Integer newMemberFlag;
	/**生效时间*/
	@Excel(name = "生效时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "生效时间")
	private Date startTime;
	/**失效时间*/
	@Excel(name = "失效时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "失效时间")
	private Date endTime;
	/**过期类型：0:固定有效期 1:时长有效期*/
	@Excel(name = "过期类型", width = 15)
	@ApiModelProperty(value = "过期类型")
	@Dict(dicCode = "coupon_expire_type")
	@TableField(updateStrategy  = FieldStrategy.IGNORED)
	private Integer expireType;
	/**过期天数*/
	@Excel(name = "过期天数", width = 15)
	@ApiModelProperty(value = "过期天数")
	@TableField(updateStrategy  = FieldStrategy.IGNORED)
	private Integer expireDays;
	/**领取后冻结天数*/
	@Excel(name = "领取后冻结天数", width = 15)
	@ApiModelProperty(value = "领取后冻结天数")
	@TableField(updateStrategy  = FieldStrategy.IGNORED)
	private Integer frozenDays;
	/**指定门店标识*/
	@Excel(name = "指定门店标识", width = 15)
	@ApiModelProperty(value = "指定门店标识")
	@Dict(dicCode = "yn")
	private Integer storeFlag;
	/**可用券导购级别，9:经理;5:店长;1:导购*/
	@Excel(name = "可用券导购级别，9:经理;5:店长;1:导购", width = 15)
	@ApiModelProperty(value = "可用券导购级别，9:经理;5:店长;1:导购")
	@Dict(dicCode = "sales_position")
	private Integer storePosition;
	/**创建人*/
	@Excel(name = "创建人", width = 15)
    @ApiModelProperty(value = "创建人")
	private String createBy;
	/**创建时间*/
	@Excel(name = "创建时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "创建时间")
	private Date createTime;
	/**更新人*/
	@Excel(name = "更新人", width = 15)
    @ApiModelProperty(value = "更新人")
	private String updateBy;
	/**更新时间*/
	@Excel(name = "更新时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "更新时间")
	private Date updateTime;
}
